import "./globals.css";
import Navbar from "./_component/navbar";

export default function ({
  children, // will be a page or nested layout
}) {
  return (
    <html lang="zh_CN">
      <body>
        <section className="drawer lg:drawer-open z-auto min-h-screen transform-none bg-zinc-50 shadow-md">
          {/* 隐藏的 my-drawer，让左侧菜单默认显示 */}
          <input id="my-drawer" type="checkbox" className="drawer-toggle" />
          <main className="drawer-content">
            <div className="lg:gap-x-12">{children}</div>
          </main>

          <aside className="drawer-side z-10">
            <label htmlFor="my-drawer" className="drawer-overlay"></label>
            <Navbar />
          </aside>
        </section>
      </body>
    </html>
  );
}
